#app {
  // width: 100%;
  // height: 100%;
  // echarts组件的样式-------------------------------------------------
  .home-echarts {
    width: 100%;
    height: 100%;
    overflow: hidden;
    .echarts-box {
      width: 100%;
      height: 100%;
      overflow: hidden;
      .my-echarts {
        width: 100%;
        height: 100%;
        background-color: #020420;
        overflow: hidden;
        canvas {
          border-radius: 20px;
        }
      }
    }
  }

  // 右侧 主展示区样式
  .main-container {
    .app-main {
      // background-color: #cdf;
      padding: 0 15px;
    }
    min-width: 1000px;   // PC端最小宽度
    background-color: #f0f0f0;
    // padding: 66px 15px 0;
    min-height: 100%;
    // min-width: 992px;
    transition: margin-left .28s;
    // margin-left: $sideBarWidth;
    margin-left: 54px;
    position: relative;
    // .dialog-footer {
    //   text-align: center;
    // }

    // 按钮样式(全局)---------------------------------------------
    .primary-btn {
      color: #fff;
      background-color: #108CFD;
    }
    .danger-btn {
      color: #fff;
      background-color: #FF5866;
    }
    // 按钮样式(全局)---------------------------------------------
    .plain-btn {
      color: $my_primary;
      &.el-button--medium {
        font-size: 12px;
        padding: 0 10px;
        border-radius: 3px !important;
      }
      &.el-button {
        height: 27px;
        border: 1px solid $my_primary !important;
      }
    }
    .fill-btn {
      color: #fff;
      &.el-button--medium {
        font-size: 12px;
        padding: 0 10px;
        border-radius: 3px !important;
      }
      &.el-button {
        height: 27px;
        background-color: $my_primary;
      }
    }
    // 新的按钮样式(全局)--------------------------------------------
    .plain-dialog-btn {
      margin-right: 30px;
      color: $my_primary;
      &.el-button--medium {
        font-size: 16px;
        padding: 0 35px;
        border-radius: 3px !important;
      }
      &.el-button {
        height: 38px;
        border: 1px solid $my_primary !important;
      }
    }
    .fill-dialog-btn {
      color: #fff;
      &.el-button--medium {
        font-size: 16px;
        padding: 0 35px;
        border-radius: 3px !important;
      }
      &.el-button {
        height: 38px;
        background-color: $my_primary;
      }
    }

    // 全局 选择框样式-------------------------------------------
    .input-box {
      display: inline-flex;
      // background-color: sandybrown;
      // margin-left: 20px;
      margin: 0 10px 0 0;
      flex-wrap: wrap;
      align-items: center;
      .item-label {
        font-size: 12px; margin-right: 5px;
      }
      // background-color: #FF5866 !important;

      .el-range-editor--medium.el-input__inner {
        height: 27px;
        font-size: 12px;
        // background-color: #FF5866;
        .el-input__icon.el-range__icon.el-icon-time {
          // background-color: #0f0;
          line-height: 19px;
        }
        .el-range-separator {
          line-height: 19px;
        }
        .el-range-input {
          // background-color: #FF5;
          font-size: 12px;
        }
      }

      .el-input--medium {
        font-size: 12px;
      }
      .el-input--medium .el-input__inner {
        height: 27px !important;
        background: transparent;
        // background: #0f0;
        -webkit-appearance: none;
        border-radius: 3px;
        // padding: 12px 5px 12px 15px;
        padding-right: 0 !important;
        color: $text_dark;
        caret-color: $text_dark;
  
        &:-webkit-autofill {
          box-shadow: 0 0 0 1000px $my_opacity inset !important;
          -webkit-text-fill-color: $text_dark !important;
        }
      }
      .el-input__suffix {
        display: inline-flex;
        align-items: center;
      }
      .el-date-editor .el-range__close-icon {
        line-height: 19px;
      }
      .el-date-editor .el-range__icon {
        line-height: 19px;
      }
    }
    // 全局输入框的样式---------------------------------------------------------
    .crud-input {
      height: 27px;
      width: 300px;
      border: 1px solid $my_primary;
      border-radius: 3px;
      &.el-input--medium {
        font-size: 12px;
      }
      &.el-input--medium .el-input__inner {
        height: 27px !important;
        background: transparent;
        border: 0;
        -webkit-appearance: none;
        border-radius: 3px;
        // padding: 12px 5px 12px 15px;
        color: $text_dark;
        caret-color: $text_dark;
  
        &:-webkit-autofill {
          box-shadow: 0 0 0 1000px $my_opacity inset !important;
          -webkit-text-fill-color: $text_dark !important;
        }
      }
      .el-input-group__append {
        color: $my_primary;
        border: 0;
        border-left: 1px solid $my_primary;
  
        .el-button {
          // height: 27px;
          // border: 1px solid $my_primary !important;
          // background-color: #f11;
        }
      }
    }

  }


  // 展开时
  .sidebar-container {
    transition: width 0.28s;
    width: $sideBarWidth !important;
    background-color: $menuBg;
    height: 100%;
    position: fixed;
    font-size: 0px;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 2001;
    overflow: hidden;

    // reset element-ui css
    .horizontal-collapse-transition {
      transition: 0s width ease-in-out, 0s padding-left ease-in-out, 0s padding-right ease-in-out;
    }

    .scrollbar-wrapper {
      overflow-x: hidden !important;
    }

    .el-scrollbar__bar.is-vertical {
      right: 0px;
    }

    .el-scrollbar {
      height: 100%;
    }

    &.has-logo {
      .el-scrollbar {
        height: calc(100% - 50px);
      }
    }

    .is-horizontal {
      display: none;
    }

    a {
      display: inline-block;
      width: 100%;
      overflow: hidden;
    }

    .svg-icon {
      margin-right: 16px;
    }

    .sub-el-icon {
      margin-right: 12px;
      margin-left: -2px;
    }

    .el-menu {
      border: none;
      height: 100%;
      width: 100% !important;
    }
    
    .el-submenu.is-active .el-submenu__title{   // 个人添加,控制submenu标题颜色
      color: $menuActiveText !important;
      i {
        color: $menuActiveText !important;
      }
    }
    .el-submenu__title {   // 个人添加: 控制submenu标题的文字颜色
      i,span {
        color: $subMenuDefaultText !important;
      }
    }
    // menu hover
    .submenu-title-noDropdown,
    .el-submenu__title {
      &:hover {
        background-color: $menuHover !important;
      }
    }

    // .is-active>.el-submenu__title {
    //   color: $subMenuActiveText !important;
    // }
    .el-menu-item.submenu-title-noDropdown > .sidebaritemtext-container {   // 个人添加,
      i,span {
        color: $subMenuDefaultText !important;
      }
    }
    .el-menu-item.is-active.submenu-title-noDropdown > .sidebaritemtext-container {   // 个人添加,
      i,span {
        color: $subMenuItemActiveText !important;
      }
    }
    & .el-menu-item > .sidebaritemtext-container {
      i,span {
        color: $subMenuItemActiveText !important;
      }
    }

    & .nest-menu .el-submenu>.el-submenu__title,
    & .el-submenu .el-menu-item {
      min-width: $sideBarWidth !important;
      background-color: $subMenuBg !important;

      &:hover {
        background-color: $subMenuHover !important;
      }
    }
    & .el-menu-item.is-active {   // 个人添加,
      background-color: $my_primary !important;
      &:hover {
        background-color: $my_primary !important;
      }
      display: flex;
      align-items: center;

      & .sidebaritemtext-container {
        // text-align: center;
        width: 100%;
        height: 43px;
        line-height: 43px;
        color: $subMenuItemActiveText !important;
      }
    }
    
  }
  // .sidebar-container .is-active {
  //   color: ;
  // }


  // 折叠 侧边栏===============================
  .hideSidebar {
    .sidebaritemtext-container {
      text-align: center !important;
    }
    .sidebar-container {
      width: 54px !important;
    }

    .main-container {
      margin-left: 54px;
    }

    .submenu-title-noDropdown {
      padding: 0 !important;
      position: relative;

      .el-tooltip {
        padding: 0 !important;

        .svg-icon {
          margin-left: 20px;
        }

        .sub-el-icon {
          margin-left: 19px;
        }
      }
    }

    .el-submenu {
      overflow: hidden;

      &>.el-submenu__title {
        text-align: center;
        padding: 0 !important;

        .svg-icon {
          margin-left: 20px;
        }

        .sub-el-icon {
          margin-left: 19px;
        }

        .el-submenu__icon-arrow {
          display: none;
        }
      }
    }

    .el-menu--collapse {
      .el-submenu {
        &>.el-submenu__title {
          &>span {
            height: 0;
            width: 0;
            overflow: hidden;
            visibility: hidden;
            display: inline-block;
          }
        }
      }
    }
  }

  .el-menu--collapse .el-menu .el-submenu {
    min-width: $sideBarWidth !important;
  }


  // 移动端样式======================
  .mobile {
    .main-container {
      // min-width: 480px !important;
      margin-left: 0px;
    }

    .sidebar-container {
      transition: transform .28s;
      width: $sideBarWidth !important;
    }

    &.hideSidebar {
      .sidebar-container {
        pointer-events: none;
        transition-duration: 0.3s;
        transform: translate3d(-$sideBarWidth, 0, 0);
      }
    }
  }

  .withoutAnimation {

    .main-container,
    .sidebar-container {
      transition: none;
    }
  }
}

// when menu collapsed
.el-menu--vertical {
  &>.el-menu {
    .svg-icon {
      margin-right: 16px;
    }
    .sub-el-icon {
      margin-right: 12px;
      margin-left: -2px;
    }
  }

  .nest-menu .el-submenu>.el-submenu__title,
  .el-menu-item {
    &:hover {
      // you can use $subMenuHover
      background-color: $menuHover !important;
    }
  }

  // the scroll bar appears when the subMenu is too long
  >.el-menu--popup {
    max-height: 100vh;
    overflow-y: auto;

    &::-webkit-scrollbar-track-piece {
      background: #d3dce6;
    }

    &::-webkit-scrollbar {
      width: 6px;
    }

    &::-webkit-scrollbar-thumb {
      background: #99a9bf;
      border-radius: 20px;
    }
  }
}
